#!/usr/bin/env python
# -*- conding: utf-8 -*-

"""
@Time     : 2024/8/31 21:42
@Author   : liujingmao
@File     : 02.HuggingFace远程推理嵌入模型.py
"""
import dotenv
from langchain_huggingface import HuggingFaceEndpointEmbeddings

dotenv.load_dotenv()

# embeddings = HuggingFaceEndpointEmbeddings(model="sentence-transformers/all-MiniLM-L12-v2")
embeddings = HuggingFaceEndpointEmbeddings(model="mattshumer/Reflection-Llama-3.1-70B")

query_vector = embeddings.embed_query("你好，我是慕小课，我喜欢打篮球游泳")

print(query_vector)
print(len(query_vector))
